From: Andres Lagar-Cavilla Date: Thu, 1 Dec 2011 14:17:14 +0000 (+0000) Subject: Tools: When passing no bitmap for the shadow log dirty bitmap clean up, we should... X-Git-Url: https://dgit.raspbian.org/%22http:/www.example.com/cgi/%22https://%22%22/%22http:/www.example.com/cgi/%22https:/%22%22?a=commitdiff_plain;h=76903750dc2800f12beed49f38a8660008dd443d;p=xen.git Tools: When passing no bitmap for the shadow log dirty bitmap clean up, we should not get EFAULT This is due to a stale check for guest_handle_null in the hypervisor, which doesn't necessarily work with the hypercall buffers. Signed-off-by: Andres Lagar-Cavilla Acked-by: Ian Jackson Committed-by: Tim Deegan --- diff --git a/tools/libxc/xc_domain.c b/tools/libxc/xc_domain.c index b6c67a2e4a..5d2a4df1b3 100644 --- a/tools/libxc/xc_domain.c +++ b/tools/libxc/xc_domain.c @@ -430,6 +430,8 @@ int xc_shadow_control(xc_interface *xch, DECLARE_DOMCTL; DECLARE_HYPERCALL_BUFFER_ARGUMENT(dirty_bitmap); + memset(&domctl, 0, sizeof(domctl)); + domctl.cmd = XEN_DOMCTL_shadow_op; domctl.domain = (domid_t)domid; domctl.u.shadow_op.op = sop;